<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class Evaluate extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('evaluate', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('user_id')->comment('用户id');
            $table->integer('goods_id')->comment('商品id');
            $table->text('evaluate_content')->comment('评价内容');
            $table->tinyInteger('star')->comment('评价星级');
            $table->tinyInteger('type')->comment('评价类型 默认好评0 好评1 中评2 差评3');
            $table->integer('evaluate_num')->comment('评价数量');
           

            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::drop('evaluate');
    }
}
